#include <cstdio>
#include <algorithm>
#include <cstring>
#include <string>
#include <iostream>
#include <map>
#include <vector>
#define _clr(x,a) memset(x,a,sizeof(x));
using namespace std;
const int N=200050;
int k;
int n;
int a[N];
map<long long,int>mp1;
map<long long,int>mp2;
map<long long,int>mp3;
int main(void){
    //freopen("data.txt","r",stdin);
    scanf("%d",&k);
    int flag=0;
    int n1,n2,n3,n4;
    for(int i=1;i<=k;i++){
        //_clr(a,0);
        long long sum=0;
        scanf("%d",&n);
        for(int j=1;j<=n;j++){
            scanf("%d",&a[j]);
            sum+=a[j];
        }
        for(int j=1;j<=n;j++){
            long long num=sum-a[j];
            if(mp1[num]){
                if(mp2[num]!=i){
                    n1=i;
                    n2=j;
                    n3=mp2[num];
                    n4=mp3[num];
                    flag=true;
                }
            }
            else{
                mp1[num]=1;
                mp2[num]=i;
                mp3[num]=j;
            }
        }
    }
    if(flag){
        printf("YES\n%d %d\n%d %d\n",n1,n2,n3,n4);
    }
    else{
        printf("NO\n");
    }
    return 0;
}
